from oss import OSSUploader

if __name__ == "__main__":
    # 初始化上传器
    uploader = OSSUploader("oss_config.json")

    # 上传整个目录，限制文件大小在 100KB 到 5MB 之间
    uploader.process_directory(
        "/Users/daxiang/Downloads/xiao",
        # max_size= 5 * 1024  # 10K
        max_size= 0.5 * 1024  # 10K
    )

    # 打印所有映射关系
    print("上传完成，映射关系:")
    for local, remote in uploader.mapping_data.items():
        print(f"{local} -> {remote}")
